﻿using System;
using PetaPoco;
using PmSoft;
using PmSoft.Caching;

namespace Modules
{
    /// <summary>
    /// 人员附件表
    ///</summary>
    [TableName("person_attachment")]
    [PrimaryKey("Id", AutoIncrement = true)]
    [CacheSetting(true)]
    [Serializable]
    public class PersonAttachment:IEntity
    {
        /// <summary>
        /// 主键 
        ///</summary>
         [Column("id"  )]
         public long Id { get; set; }
        /// <summary>
        /// 人员ID 
        ///</summary>
         [Column("person_id"  )]
         public int PersonId { get; set; }
        /// <summary>
        /// 附件类型 
        ///</summary>
         [Column("type"  )]
         public byte Type { get; set; }
        /// <summary>
        /// 附件ID 
        ///</summary>
         [Column("attachment_id"  )]
         public string AttachmentId { get; set; }
        /// <summary>
        /// 附件相对路径（老数据导入） 
        ///</summary>
         [Column("path"  )]
         public string Path { get; set; }

    #region IEntity 成员

        [Ignore]
        object IEntity.EntityId { get { return this.Id; } }

      #endregion

    }
}
